package com.xbongbong.saas.model;

import com.xbongbong.paas.toolbox.exception.XbbException;
import com.xbongbong.saas.domain.entity.CouponTempleteEntity;

import java.util.List;
import java.util.Map;
import java.util.Set;


/**
 * @author bomfish
 */
public interface CouponTempleteModel {
   Long insert(CouponTempleteEntity entity) throws XbbException;

   void insertBatch(List<CouponTempleteEntity> list);

   List<CouponTempleteEntity> findEntities(Map<String, Object> param);

   Integer getEntityCount(Map<String, Object> param);

   void update(CouponTempleteEntity entity) throws XbbException;

   CouponTempleteEntity getByKey(Long key, String corpid);

   Integer deleteByKey(Long key, String corpid) throws XbbException;

   Integer getOnlineCouponCount(String corpid);

   void updateUsedNum(Set<Long> idIn, List<CouponTempleteEntity> updateList, String corpid) throws XbbException;

   void updateStatus(List<CouponTempleteEntity> updateList, String corpid) throws XbbException;

    List<String> findCorpid();
}
